import {createRouter, createWebHistory} from 'vue-router'

import UserAgreement from '../views/documents/UserAgreement.vue'
import PrivacyPolicy from '../views/documents/PrivacyPolicy.vue'
import LogIn from "@/views/LogIn.vue";
import InvitePage from "../views/InvitePage.vue";
import SuccessPage from '@/views/SuccessPage.vue'
import DownloadPage from '@/views/DownloadPage.vue'

const routes = [
    {
        path: '/',
        redirect: '/invite-page'
    },
    {
        path: '/log-in',
        name: 'LogIn',
        component: LogIn
    },
    {
        path: '/invite-page',
        name: 'InvitePage',
        component: InvitePage
    },
    {
        path: '/user-agreement',
        name: 'UserAgreement',
        component: UserAgreement
    },
    {
        path: '/privacy-policy',
        name: 'PrivacyPolicy',
        component: PrivacyPolicy
    },
    {
        path: '/success-page',
        name: 'SuccessPage',
        component: SuccessPage
    },
    {
        path: '/download-page',
        name: 'DownloadPage',
        component: DownloadPage
    }
]

const router = createRouter({
    history: createWebHistory(), // Vue3 使用 createWebHistory
    routes
})

export default router